<?php echo $this->doctype(); ?>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<?php 
				echo $this->headTitle();
				echo $this->headLink();
				$this->jQuery()->enable();
				echo $this->jQuery();
				echo $this->headScript();
		?>
	</head>
	
	<body>
		<div id="global">
			<div id="header">
				
				<div id="menu">
					<ul>
						<li>
							<a href="<?php echo $this->url(array('controller' => 'index'), null, true); ?>">Accueil</a>
						</li>
						<li<?php echo ($this->controller == 'about') ? ' class="selected"' : ''; ?>>
							<a href="<?php echo $this->url(array('controller' => 'about', 'action' => 'hybrid-legacy'), null, true); ?>">A propos</a>
						</li>
						<li<?php echo ($this->controller == 'gallery') ? ' class="selected"' : ''; ?>><a href="<?php echo $this->url(array('controller' => 'gallery'), null, true); ?>">Galerie</a></li>
						<li<?php echo ($this->controller == 'calendar') ? ' class="selected"' : ''; ?>><a href="<?php echo $this->url(array('controller' => 'calendar'), null, true); ?>">Calendrier</a></li>
						<li<?php echo ($this->controller == 'forum') ? ' class="selected"' : ''; ?>><a href="<?php echo $this->url(array('controller' => 'forum'), null, true); ?>">Forum</a></li>
						<li<?php echo ($this->controller == 'contact') ? ' class="selected"' : ''; ?>><a href="<?php echo $this->url(array('controller' => 'contact'), null, true); ?>">Contact</a></li>
						<?php if($this->is_logged) { ?>
							<li><a href="<?php echo $this->url(array('module' => 'backend', 'controller' => 'user', 'action' => 'signout'), null, true); ?>"><img src="<?php echo $this->baseUrl(); ?>/images/icons/signout.png" alt="Déconnexion" /></a></li>
						<?php } ?>
					</ul>
				</div>
				
			</div>
			
			<div id="content">
				<?php echo $this->layout()->content; ?>
			
				<div id="clear_both"></div>
			</div>
			
			<div id="footer">
				
				<ul>
					<li>Le site
						<ul>
							<li><a href="<?php echo $this->url(array('controller' => 'about'), null, true); ?>">A propos</a></li>
							<li><a href="<?php echo $this->url(array('controller' => 'gallery'), null, true); ?>">Galerie</a></li>
							<li><a href="<?php echo $this->url(array('controller' => 'calendar'), null, true); ?>">Calendrier</a></li>
							<li><a href="<?php echo $this->url(array('controller' => 'forum'), null, true); ?>">Forum</a></li>
							<li><a href="<?php echo $this->url(array('controller' => 'contact'), null, true); ?>">Contact</a></li>
						</ul>
					</li>
					<li>Nous suivre
						<ul>
							<li>
								<a href="http://www.facebook.com/hybridlegacy">
								<img src="<?php echo $this->baseUrl(); ?>/images/icons/facebook.png" alt="Facebook" /> Facebook</a>
							</li>
							<li>
								<a href="http://twitter.com/#!/hybridlegacy">
									<img src="<?php echo $this->baseUrl(); ?>/images/icons/twitter.png" alt="Twitter" /> Twitter
								</a>
							</li>
							<?php
							/*
							<li><a href=""><img src="<?php echo $this->baseUrl(); ?>/images/icons/youtube.png" alt="Youtube" /></a></li>
							*/
							?>
						</ul>
					</li>
					<li>Derniers articles
						<?php if(!is_null($this->articles) and !empty($this->articles)) { ?>
						<ul>
							<?php foreach($this->articles as $a) { ?>
							<li>
								<a href="<?php echo $this->url(array('controller' => 'article', 'action' => $a['keyname']), null, true); ?>"><?php echo $a['title']; ?></a>
							</li>
							<?php } ?>
						</ul>
						<?php } ?>
					</li>
					<li>Derniers sujets
						<?php if(!is_null($this->subjects) and !empty($this->subjects)) { ?>
						<ul>
							<?php foreach($this->subjects as $s) { ?>
							<li>
								<a href="<?php echo $this->url(array('controller' => 'forum', 'action' => 'subject', 'view' => $a['keyname']), null, true); ?>"><?php echo $s['title']; ?></a>
							</li>
							<?php } ?>
						</ul>
						<?php } ?>
					</li>
				</ul>
				
				<div class="clear_both"></div>
				
				<div id="copyright">
					Copyright © 2011 Hybrid Legacy<br />
					Developed by <a href="http://micster.fr">Micster</a>
				</div>
			</div>
		</div>
	</body>
</html>
